package com.east.mapper;

import com.east.common.DataFilter;
import com.east.dto.ClueDTO;
import com.east.dto.NameValueDTO;
import com.east.entity.Clue;
import com.east.query.ClueQuery;

import java.util.List;

/**
* @author eastj
* @description 针对表【t_clue(线索表)】的数据库操作Mapper
* @createDate 2025-01-17 20:43:35
* @Entity com.east.entity.Clue
*/
public interface ClueMapper {

    int deleteByPrimaryKey(Long id);

    int insert(Clue record);

    int insertSelective(Clue record);

    Clue selectByPrimaryKey(Long id);

    int updateByPrimaryKeySelective(Clue record);

    int updateByPrimaryKey(Clue record);
    @DataFilter(tableAlias = "tc", fieldName = "owner_id")
    List<ClueDTO> list(ClueQuery clueQuery);

    int insertBatch(List<ClueDTO> clueList);

    List<ClueDTO> phoneExists(String phone,Integer clueId);

    ClueDTO selectCascadeByPrimaryKey(long clueId);

    int batchDeleteByIds(Integer[] ids);

    int updateState(Integer clueId,int state);

    int totalNum();

    List<NameValueDTO> sourceTotalCount();
}
